﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Areas/Admin/Views/Shared/AdminMaster.Master" Inherits="System.Web.Mvc.ViewPage<VietThuongLMS.Areas.Admin.Models.ChiNhanhModel>" %>

<asp:Content ID="Content2" ContentPlaceHolderID="head" runat="server">
    <script type="text/javascript" src="<%: Url.Content("~/Scripts/MicrosoftAjax.js") %>"></script>
    <script type="text/javascript" src="<%: Url.Content("~/Scripts/MicrosoftMvcValidation.js") %>"></script>
    <script type="text/javascript" src="<%: Url.Content("~/Plugins/ckeditor/ckeditor.js") %>"></script>
</asp:Content>

<asp:Content ID="Content1" ContentPlaceHolderID="MainContent" runat="server">
<legend>
        <h2>
            Cập nhật chi nhánh</h2>
    </legend>
    <% Html.EnableClientValidation();
       using (Html.BeginForm("Edit", "ChiNhanh", new { area = "Admin" }, FormMethod.Post, new { @class = "form-horizontal", @id = "formNew", @name = "formNew", enctype = "multipart/form-data" }))
       {
    %>
    <%: Html.HiddenFor(t => t.ID) %>
    <%: Html.ValidationSummary(true) %>
    <div class="control-group">
        <label class="control-label" for="strFrom">
            Tên chi nhánh:</label>
        <div class="controls">
            <%: Html.TextBoxFor(t => t.TenChiNhanh, new { @class = "h30 span12", placeholder = "Tên chi nhánh..." })%>
            <%: Html.ValidationMessageFor(m => m.TenChiNhanh)%>
        </div>
    </div>
    <div class="control-group">
        <label class="control-label" for="strFrom">
            Địa chỉ:</label>
        <div class="controls">
            <%: Html.ValidationMessageFor(m => m.DiaChi)%>
            <%: Html.TextBoxFor(t => t.DiaChi, new { @class = "span12", placeholder = "Địa chỉ..." })%>
        </div>
    </div>
    <div class="control-group">
        <label class="control-label" for="strFrom">
            Mô tả:</label>
        <div class="controls">
            <%: Html.ValidationMessageFor(m => m.MoTa)%>
            <%: Html.TextAreaFor(t => t.MoTa, new { @class = "ckeditor", placeholder = "Mô tả..." })%>
        </div>
    </div>
    <div class="control-group">
        <label class="control-label" for="strFrom">
            Hình bìa:</label>
        <div class="controls">
            <img src="<%=ResolveUrl("~/Images/ChiNhanh/")%><%=@Model.strUrlAvatar %>" alt="<%=@Model.strUrlAvatar %>" style="width:150px; height:150px" />
            <br />
            <%: Html.TextBoxFor(t => t.UrlAvatar, new { id = "UrlAvatar", type = "file" })%>
            <%: Html.ValidationMessageFor(m => m.UrlAvatar)%>
        </div>
    </div>
    <div class="control-group">
        <label class="control-label" for="strFrom">
            Hình bìa 2:</label>
        <div class="controls">
            <img src="<%=ResolveUrl("~/Images/ChiNhanh/")%><%=@Model.strUrlAvatar2 %>" alt="<%=@Model.strUrlAvatar2 %>" style="width:150px; height:150px" />
            <br />
            <%: Html.TextBoxFor(t => t.UrlAvatar2, new { id = "UrlAvatar", type = "file" })%>
            <%: Html.ValidationMessageFor(m => m.UrlAvatar2)%>
        </div>
    </div>
    <div class="control-group">
        <label class="control-label" for="strFrom">
            Hình bìa 3:</label>
        <div class="controls">
            <img src="<%=ResolveUrl("~/Images/ChiNhanh/")%><%=@Model.strUrlAvatar3 %>" alt="<%=@Model.strUrlAvatar3 %>" style="width:150px; height:150px" />
            <br />
            <%: Html.TextBoxFor(t => t.UrlAvatar3, new { id = "UrlAvatar", type = "file" })%>
            <%: Html.ValidationMessageFor(m => m.UrlAvatar3)%>
        </div>
    </div>
    <div class="control-group">
        <label class="control-label" for="strFrom">
            Hình bìa 4:</label>
        <div class="controls">
            <img src="<%=ResolveUrl("~/Images/ChiNhanh/")%><%=@Model.strUrlAvatar4 %>" alt="<%=@Model.strUrlAvatar4 %>" style="width:150px; height:150px" />
            <br />
            <%: Html.TextBoxFor(t => t.UrlAvatar4, new { id = "UrlAvatar", type = "file" })%>
            <%: Html.ValidationMessageFor(m => m.UrlAvatar4)%>
        </div>
    </div>
    <div class="control-group">
        <label class="control-label" for="strFrom">
            Hình bìa 5:</label>
        <div class="controls">
            <img src="<%=ResolveUrl("~/Images/ChiNhanh/")%><%=@Model.strUrlAvatar5 %>" alt="<%=@Model.strUrlAvatar5 %>" style="width:150px; height:150px" />
            <br />
            <%: Html.TextBoxFor(t => t.UrlAvatar5, new { id = "UrlAvatar", type = "file" })%>
            <%: Html.ValidationMessageFor(m => m.UrlAvatar5)%>
        </div>
    </div>
    <div class="control-group">
        <div class="controls">
            <button id="btnCreate" name="btnCreate" type="submit" class="btn btn-primary">Cập nhật</button>
        </div>
    </div>
    <% } %>
</asp:Content>

